@mixin transition($v) {
  transition: $v;
}

@mixin borderRadius($v) {
  -ms-border-radius: &v;
  border-radius: $v;
}

/*3.6 图片
  name:  hui-image
*/

/*3.6.1 图片效果
<img src="" class="hui-image hui-image-responsive radius round hui-thumbnail" />
hui-image-responsive 响应式    .radius 圆角图片    .round 圆形图片   .hui-thumbnail 缩略图
*/

.hui-image {
  &.hui-thumbnail {
    display: inline-block;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    max-width: 100%;
    height: auto;
    padding: 4px;
    line-height: 1.42857143;
    background-color: #fff;
    border: 1px solid #ddd;
    @include transition(all .2s ease-in-out);
  }
  &.hui-image-responsive {
    display: inline-block;
    max-width: 100%;
    height: auto
  }
}

@media (max-width: 767px) {
  .hui-image {
    &.hui-image-responsive {
      width: 100%
    }
  }
}

.duang-opacity img {
  @include transition(opacity .1s linear);
}

.duang-opacity a:hover img,
a:hover .opacity img {
  opacity: 0.85;
  filter: alpha(opacity=85)
}

/*3.6.2 图集效果
  name:      hui-album
  example:
    <div class="hui-album" style="width:160px">
      <div class="hui-album-img">
        <img src="" style="height: 160px;">
      </div>
      <div class="hui-album-title">《仙剑奇侠传》赵灵儿<span class="c-999">(20张)</span></div>
      <div class="hui-album-bg">
        <div class="hui-album-bg-fir"></div>
        <div class="hui-album-bg-sec"></div>
      </div>
    </div>
*/
.hui-album {
  .hui-album-img {
    border: 1px solid #e0e0e0;
    img {
        display: block;
        width: 100%
    }
  }
  .hui-album-title {
    display: block;
    text-align: left;
    padding: 7px 5px;
    line-height: 18px;
    color: #555;
    text-decoration: none;
    font-size: 12px;
    border: solid 1px #e0e0e0;
    border-top: 0;
  }
  .hui-album-bg {
    .hui-album-bg-fir,
    .hui-album-bg-sec {
      border: 1px solid #e6e6e6;
      border-top: 1px solid #f5f5f5;
      height: 1px;
      margin: 0 auto;
      overflow: hidden;
    }
    .hui-album-bg-fir {
      margin: 0 3px;
    }
    .hui-album-bg-sec {
      margin: 0 6px;
    }
  }
}

/*3.6.3 头像
Name:       hui-avatar
Example:    <i class="hui-avatar size-L radius"><img src="static/h-ui/images/ucenter/avatar-default.jpg"></i>
*/
.hui-avatar {
  display: inline-block;
  position: relative;
  overflow: hidden;
  width: 32px;
  height: 32px;
  img {
    display: block;
    width: 32px;
    height: 32px;
  }
  &.radius,
  &.radius img {
    @include borderRadius(50%);
  }
  &.size-MINI {
    width: 16px;
    height: 16px;
    img {
      width: 16px;
      height: 16px;
    }
  }
  &.size-S{
    width: 24px;
    height: 24px;
    img {
      width: 24px;
      height: 24px;
    }
  }
  &.size-M{
    width: 32px;
    height: 32px;
    img {
      width: 32px;
      height: 32px;
    }
  }
  &.size-L{
    width: 48px;
    height: 48px;
    img {
      width: 48px;
      height: 48px;
    }
  }
  &.size-XL {
    width: 64px;
    height: 64px;
    img {
      width: 64px;
      height: 64px;
    }
  }
  &.size-XXL {
    width: 100px;
    height: 100px;
    img {
      width: 100px;
      height: 100px;
    }
  }
  &.size-XXXL {
    width: 128px;
    height: 128px;
    img {
      width: 128px;
      height: 128px;
    }
  }
}